package mapping

import (
	"maya-service/model"
	"maya-service/model/entity"
)

// AiModulesEntityToDto entity data transfer
func AiModulesEntityToDto(aiModules []*entity.AiModule) []*model.AiModuleInfo {
	out := make([]*model.AiModuleInfo, 0, len(aiModules))
	for _, c := range aiModules {
		out = append(out, AiModuleEntityToDto(c))
	}
	return out
}

// AiModuleEntityToDto entity data transfer
func AiModuleEntityToDto(e *entity.AiModule) *model.AiModuleInfo {
	return &model.AiModuleInfo{

		Id: e.Id,

		Name: e.Name,

		Images: e.Images,

		BotId:       e.BotId,
		AccessToken: e.AccessToken,

		Heat:      e.Heat,
		CreatedAt: e.CreatedAt,

		UpdatedAt: e.UpdatedAt,
	}
}
